import VueRouter from 'vue-router';
import index from '../../components/index/index';
import search from "../../components/index/search";
import paihang from "../../components/index/paihang";
import youshengshu from "../../components/index/youshengshu";
import yanqing from "../../components/index/yanqing";
import zonghe from "../../components/yanqing/zonghe";
import mostplay from "../../components/yanqing/mostplay";
import mostnew from "../../components/yanqing/mostnew";
import One_mianfei from "../../components/paihang/One_mianfei";
import One_biaosheng from "../../components/paihang/One_biaosheng";
import Two_hot from "../../components/paihang/Two_hot";
import Two_youshengshu from "../../components/paihang/Two_youshengshu";
import details from "../../components/index/details";
import Two_hot_one from "../../components/paihang/Two_hot_one";
import Two_youshengshu_one from "../../components/paihang/Two_youshengshu_one";
import search_content from "../../components/search/search_content";
import search_content_one from "../../components/search/search_content_one";

export default new VueRouter({
  routes:[
    {
      path:'/index',
      component:index,
    },
    {
      path: '/search_content',
      component: search,
      children:[
        {
          path:'/search_content',
          component: search_content
        },
        {
          path:'/search_content_one',
          component: search_content_one
        }
      ]
    },
    //排行榜
    {
      path: '/Two_hot',
      component: paihang,
      children:[
          {
            path:'/One_mianfei',
            component:One_mianfei,
            children:[
              {
                path:'/Two_hot',
                component:Two_hot
              },
              {
                path: '/Two_youshengshu',
                component:Two_youshengshu
              }
            ],
            redirect:'/Two_hot'
          },
          {
            path:'/Two_hot_one',
            component:One_biaosheng,
            children:[
              {
                path:'/Two_hot_one',
                component:Two_hot_one
              },
              {
                path: '/Two_youshengshu_one',
                component:Two_youshengshu_one
              }
            ]
            // redirect:'/Two_hot'
          }
      ]
    },
    //有声书
    {
      path:'/youshengshu',
      // name:'youshengshu',
      component:youshengshu,
    },
    //言情
    {
      path: '/zonghe',
      component: yanqing,
      children:[
          {
            path:'/zonghe',
            component:zonghe
          },
          {
            path:'/mostplay',
            component:mostplay
          },
          {
            path:'/mostnew',
            component:mostnew
          }
      ]
    },
    //详情页
    {
      path:'/details',
      component: details
    },
    {
      path:'/*',
      redirect:'/index'
    }
  ]
})
